import request from '../utils/request';
import { api } from '../utils/config';

  export async function queryAll () {
    return request(`${api}/list`,{
        method: 'get'
      }
    )
  }

  export async function remove (data) {
    const id = data.payload.id;
    return request( `${api}delete?id=${id}`, {
      method:'get'
    })
  }

  export async function query (payload) {
    return request(`${api}/query`,{
        method: 'post',
        data: payload,
      }
    )
  }
